<link href="admin.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="<{$config.weburl}>/script/jquery-1.4.4.min.js"></script>
<script type="text/javascript" src="<{$config.weburl}>/script/jquery.ui.js"></script>
<div class="container">
<div class="oflow" style="height:330px">
<form name="form1" id="form1" action="module.php?m=product&s=order_opear.php" method="post">
<input name="id" type="hidden" id="id" value="<{$de.order_id}>">
<input name="uid" type="hidden" id="uid" value="<{$de.member_id}>">
<table class="table">
    <thead>
        <tr>
            <th class="partition" colspan="99">订单详情</th>
        </tr>
    </thead>
    <tbody>
    <tr>
        <td width="60">订单编号</td>
        <td colspan="3"><{$de.order_id}> <b class="org"><{$de.order_pay_status}></b></td>
    </tr>
    <tr>
        <td>产品总价:</td>
        <td width="200"><{$config.money}><{$de.cost}></td>
		<td width="60">配送费用:</td>
        <td><{$config.money}><{$de.freight}></td>
    </tr>
    <tr>
        <td>行邮税:</td>
        <td width="200"><{$config.money}><{$de.tax_price}></td>
		<td width="60">优惠券:</td>
        <td>-<{$config.money}><{$de.cpns_price}></td>
    </tr>
    <tr>
    	<td>活动优惠:</td>
        <td width="200">-<{$config.money}><{$de.discount}></td>
    	<td>余额支付:</td>
        <td>-<{$config.money}><{$de.cash_price}></td>
    </tr>
    <tr>
        <td>保险费:</td>
        <td><{$config.money}><{$de.insurance_fee}></td>
        <td>应付总额:</td>
        <td><{$config.money}><{$de.cost+$de.freight+$de.tax_price+$de.insurance_fee-$de.cash_price-$de.cpns_price-$de.discount}></td>
    </tr>
    <tr>
        <td>下单时间:</td>
        <td colspan="5"><{$de.create_time|date_format:"%Y-%m-%d&nbsp;%H:%M:%S"}></td>
    </tr>
    <tr>
    	<td>支付方式：</td>
        <td colspan="3">
        <{if $de.status==1}>
            <select name="payment_id" class="w162">
            <{foreach item=list from=$pay}>
                <option <{if $de.payment_id==$list.payment_id}>selected="selected"<{/if}> value="<{$list.payment_id}>"><{$list.payment_name}></option>
            <{/foreach}>
            </select>
        <{else}>
			<{$de.payment_name}>
        <{/if}>
        </td>
    </tr>
    </tbody>
</table>
<div class="dialog_button">
<{if $de.status==1}>
    <input id="save" type="button" value="付费">
    <input name="act" type="hidden" id="action" value="pay"> 
<{else}>
    <input id="close" type="button" value="关闭">
<{/if}>  
</div>
</form>
<div id="error"></div> 
<script>
function $$(id) {
	return !id ? null : document.getElementById(id);
}
function ajaxpost(formid) {
	var ajaxframeid = 'ajaxframe';
	var ajaxframe = $$(ajaxframeid);
	if(!ajaxframe){
		var div = document.createElement('div');
		div.style.display = 'none';
		div.innerHTML = '<iframe name="' + ajaxframeid + '" id="' + ajaxframeid + '" loading="1"></iframe>';
		ajaxframe = $$(ajaxframeid);
		$$('append_parent').appendChild(div);
	}
	$$(formid).target = ajaxframeid;
	$$(formid).submit();
	window.parent.main.document.location.reload();
	DialogManager.close("order");
}
$("#save").click(function () {
	ajaxpost("form1");
	return false;
});
$("#close").click(function () {
	window.parent.main.document.location.reload();
	DialogManager.close("order");
});
</script>
</form>
</div>
</div>